﻿using System;
using System.Collections.Generic;
using System.Data.Entity;
using System.Linq;
using System.Text;
using Jemer.Domain.Entities;

namespace Jemer.Data
{
    public class JemerContext : DbContext
    {
        public DbSet<NewsInfo> NewsInfoes { get; set; }
        public DbSet<OrderInfo> OrderInfoes { get; set; }
        public DbSet<OrderListInfo> OrderListInfoes { get; set; }
        public DbSet<ProductAdvisoryInfo> ProductAdvisoryInfoes { get; set; }
        public DbSet<ProductComment> ProductComments { get; set; }
        public DbSet<ProductImg> ProductImg { get; set; }
        public DbSet<ProductTag> ProductTag { get; set; }
        public DbSet<ProductTagMapping> ProductTagMapping { get; set; }
        public DbSet<ProductType> ProductType { get; set; }
        public DbSet<SystemInfo> SystemInfoes { get; set; }
        public DbSet<UserAccount> UserAccounts { get; set; }
        public DbSet<UserAddressInfo> UserAddressInfoes { get; set; }
        public DbSet<UserArchive> UserArchives { get; set; }
        public DbSet<UserCollection> UserCollections { get; set; }
        public DbSet<UserInfo> UserInfoes { get; set; }
        public DbSet<UserPointInfo> UserPointInfoes { get; set; }
        public DbSet<UserRecommendation> UserRecommendations { get; set; }

        /// <summary>
        /// 提交虚方法
        /// </summary>
        public virtual void Commit()
        {
            base.SaveChanges();
            string s="";
            s = s.Substring(0, 1).ToLower() + s.Substring(1, s.Length - 1);
        }
    }
}
